//package lzzy.edu.cn.demothymeleaf.service;
//
//import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
//import lzzy.edu.cn.demothymeleaf.entity.Customer;
//import lzzy.edu.cn.demothymeleaf.repository.CustomerRepository;
//import org.springframework.beans.factory.annotation.Autowired;
//import org.springframework.cache.annotation.Cacheable;
//import org.springframework.stereotype.Service;
//
//@Service
//public class CustomerService {
//    @Autowired
//    private CustomerRepository customerRepository;
//    @Cacheable(cacheNames = "customer",key = "result.id")
//    public Customer getCustomer(String username){
//        return customerRepository.findByUsername(username);
//    }
//}